local nieqiao = fk.CreateSkill{
  name = "hanqing__nieqiao",
}

Fk:loadTranslationTable{
  ["hanqing__nieqiao"] = "蹑蹻",
  [":hanqing__nieqiao"] = "当你拼点时，所有角色可以用装备区的牌拼点。",
}

nieqiao:addEffect(fk.BeforeRequestAsk, {
  can_refresh = function (self, event, target, player, data)
    if player:hasSkill(nieqiao.name) and data and data.focus_text == "AskForPindian" then
      local pindian_event
      for _, t in ipairs({ GameEvent.Pindian, GameEvent.JointPindian, GameEvent.DelayedPindian }) do
        pindian_event = player.room.logic:getCurrentEvent():findParent(t, true)
        if pindian_event then
          break
        end
      end
      if pindian_event then
        local pindian = pindian_event.data
        if pindian.from == player or table.contains(pindian.tos, player) then
          return true
        end
      end
    end
  end,
  on_refresh = function (self, event, target, player, data)
    data = data or {}
    for _, v in pairs(data.data) do
      v[4].include_equip = true
    end
  end,
})

return nieqiao
